----------------------------------------------------------------------------- WinStats Version 1.3 (C) Copyright Allen L. Lang, 1994 ALL RIGHTS RESERVED ----------------------------------------------------------------------------- A utility to help you dynamically monitor Windows System Resources! Does Windows mysteriously slow down at times? Have you ever been frustrated by Windows' refusing to open a new application? You have megabytes of RAM available, but Windows will not load a new application (sometimes giving you an "out of memory" message). The reason may be a shortage of Windows System Resources. WinStats dynamically monitors Windows System Resources and displays the percent free in three formats: - condensed in WinStats' icon (which can be set "on top"). - in the title bar of your active application. - in the WinStats window (as a bar graph). You can easily tell when Windows is getting low on free resources and take action before your favorite application will refuse to start. WinStats requires Windows 3.1 or later. Let's get the formalities out of the way before exploring WinStats' capabilities ... LICENSE ------- All rights are reserved. WinStats is Shareware. License fee is $5.00. You may evaluate WinStats for up to 30 days. After that period, if you continue to use WinStats, then it must be licensed by sending the fee to: Allen L. Lang 121 Windsor Commons Cranbury, NJ 08512 Include your name, address, e-mail address (if you have one), and name/phone of BBS where you obtained WinStats (so I cam upload the newest versions when they become available). WinStats may be copied, uploaded, or distributed provided: all files from this package are included, as is, and in their entirety (including the license and warranty statements), and that no fee is charged for such copies beyond the expense of duplication, media, and distribution. The author's rights extend to all copies so made. WARRANTY -------- WinStats is not covered by any warranty, expressed or implied. The author will not be liable for anything that happens as a result of any use of, or the inability to use, WinStats in your particular application. Stated another way: THIS PROGRAM IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. ======================================================================== Phew, I hate that part. Now let's get to the good stuff: what is WinStats and how do you use it ... WinStats ------- A utility to help you get your to-do list to-done! Contents -------- 1.0 Overview of Windows System Resources 2.0 Installing WinStats 3.0 Customizing WinStats 3.1 WinStats Icon 3.2 WinStats Main Window 3.2.1 Options 3.2.2 Lists 3.2.3 Exit 3.2.4 Clear 3.2.5 About 4.0 Typical Use of WinStats 5.0 Technical Support 1.0 Overview of Windows System Resources ---------------------------------------- We've all heard the term GUI (Graphical User Interface). In order to implement a GUI, Windows stores data about its graphical components in data structures. Memory for these data structures is obtained dynamically (at the time the graphical component is created). For example, when a new window is opened, Windows must allocate memory for a data structure that defines the window's owner (the program or process), its size, position, colors, fonts, etc., etc. Many windows have "controls" (such as buttons, lists, scroll bars, menus etc.). Windows must also allocate memory for the data structures that define these "controls". Each structure that Windows creates is allocated from the pool of Free System Resources (FSR). This pool is made up of storage areas (heaps) that reside in two Windows programs: GDI.EXE (manages graphics and printing) and USER.EXE (manages user input and output). In Windows 3.1, GDI has one 64K heap and USER has two 64K heaps. These heaps are used to store local variables for GDI.EXE and USER.EXE. The remainder (i.e., the "free" portion) of these heaps is used to allocate storage for the data structures necessary to represent each graphical component created by Windows. In addition to the GDI and USER heaps, virtual memory resources are needed to start a graphical application on your PC. Virtual memory is made up of real memory (RAM) plus the Windows swap file (on your hard disk). The Program Manager's About box displays a value for Memory and System Resources. However, the memory information is not in a very useful form, and the About box is not easily visible while you work. The Memory figure is free megabytes of virtual memory (real memory plus swap file). Not very useful if you don't know the total virtual memory configured on your PC (% free would be a more useful statistic). The System Resources value is actually the minimum of the % free USER and % free GDI heaps. To see the Program Manager's About box, you must first get to the Program Manager, click Help, then click About. Once you get to the About box, there's no easy way to keep this information visible while you work. WinStats will dynamically monitor these three resources (GDI heap, USER heap, and virtual memory) and will display the % free statistics of each. You have the choice of seeing these stats in three formats: - condensed in WinStats' icon (which can be set "on top"). - in the title bar of your active application. - in the WinStats window (as a bar graph). In the first and last case, the values displayed are color coded to help you quickly spot resource problems. The colors correspond to % free: Green: 100% - 60% Yellow: 59% - 30% Red: 0% - 29% 2.0 Installing WinStats ----------------------- The directory containing this README.TXT file will be referred to as the "distribution directory". The distribution directory should contain the following files: DDEML.DL_ README.TXT SETUP.EXE SETUP.LST SETUP1.EX_ SETUPKIT.DL_ THREED.VB_ VBRUN300.DL_ VER.DL_ WINSTATS.CF_ WINSTATS.EX_ WINSTATS.IN_ If you have placed the distribution directory on your hard disk, it should be given a temporary name (for example C:\JUNK). Do NOT use the name WINSTATS since this will be the name of WinStats' permanent directory. After installation, the distribution directory can be removed from your hard disk to save space (save a copy of the distribution directory on a floppy). Some of the files in the distribution directory are compressed; some are only needed for the installation process. Follow the installation directions (below). It contains steps to uncompress the files needed for WinStats and place them in a permanent WinStats directory on your hard disk. To install WinStats: 1) If you have any Visual Basic applications running, shut them down. If you don't know whether any of your apps were created with Visual Basic, SETUP.EXE (step 4) will detect and tell you to shut them down. Unfortunately, SETUP.EXE can only tell if a VB application is running, but not its name. If necessary, shut down all apps. 2) Start Windows File Manager. 3) Open a window for the distribution directory. 4) Double click SETUP.EXE (careful, there are several files with similar names) and follow instructions. SETUP.EXE is an automated install program. It will first create a permanent directory for WinStats (default is C:\WINSTATS). Then, it will uncompress files from the distribution directory, and copy them to the proper directories on your hard disk. The files copied are described below: The following files are uncompressed and copied to C:\WINSTATS: WINSTATS.EXE - executable (less than 50K of disk space required) WINSTATS.INI - customizable options (less than 2K of disk space) WINSTATS.CFG - initial exclude file (14 bytes) The following files are uncompressed and copied to either the \WINDOWS or the \WINDOWS\SYSTEM dir (depending upon whether you already have an existing version; only older versions will be replaced). These files are needed to run applications created with Visual Basic. However, they can be shared by all VB apps. So if you already have VB apps on your PC, these files may already exist on your hard disk. If none of these files exist, you will need about 513K free on your hard disk to install. VER.DLL (9K) DDEML.DLL (39K) VBRUN300.DLL (400K) THREED.VBX (65K) The installation process will create a WinStats group in your Program Manager. After the installation is complete, drag the WinStats icon from the WinStats group to your STARTUP group (so WinStats will automatically start when you start Windows). You can then delete the WinStats group and its icon if you wish. To manually start WinStats, just double click its icon or double click WINSTATS.EXE from the C:\WinStats directory. After installation is complete, you can remove the original distribution directory from your hard disk (save a copy on a floppy disk first). Do NOT delete the files in C:\WINSTATS 3.0 Customizing WinStats ------------------------ When WinStats starts, you will either see the main window, or (if you have the "keep icon on top" option set) you'll see the WinStats Icon. 3.1 WinStats Icon ----------------- When WinStats is minimized, its icon will show the percent free for each of the three resources: USER, GDI, Memory. In order to save space, only the first letter of the resource's name is shown along with the % free. For example, the icon might appear as follows: U81 G73 M94 This would mean that the USER heap was 81% free, the GDI heap was 73% free, and virtual memory was 94% free. The values displayed are color coded based on % free (green: 100% - 60%; yellow: 59% - 30%; red: 29% - 0%). WinStats' icon can be set "on top" (see Section 3.2.1 Options) and placed in the corner of your screen for easy viewing. In this way, you'll always have a view of system resource status. WinStats cannot be customized from its icon. In order to customize WinStats, you must activate the main window (double click the icon). 3.2 WinStats Main Window ------------------------ From WinStats main window, the % free system resources are displayed as color coded bar graphs (green: 100% - 60%; yellow: 59% - 30%; red: 29% - 0%). The main window's menu bar can be used to customize WinStats. Menu choices include: Options, Lists, Exit, Clear, and About. These are described in the following sections. 3.2.1 Options ------------- The Options menu will open a window showing several parameters that can be set to customize WinStats. Click the buttons associated with the options you desire, then click OK. To exit without accepting any of the changes you made in this window, click CANCEL (in this case, the options will remain set as they existed prior to opening the Options window). The status of all options is kept in WINSTATS.INI which resides in WinStats program directory. The options that can be set to customize WinStats include: "Monitor Frequency". Use the scroll bar to select a frequency for monitoring system resources. 1 to 60 seconds can be selected. This value is used to set a timer's interval. Each time the interval expires, WinStats will examine the system resources, obtain new % free values, and update the display (if any value has changed). Use a small number to get an instantaneous view of resource usage. Use a larger number if you want to avoid impacting your CPU usage. "Add stats to active title bar". In addition to displaying resource statistics in WinStats icon and main window, you can display these statistics in the title bar of whatever window is active. This gives you a method for always keeping Window's resource data in view. You have several choices for the data to be added in the active window's title bar: - Time current time (displayed as hh:mm in 24 hr clock format). - Resources % free USER heap, GDI heap, and Memory (displayed as Uxx:Gxx:Mxx). - Both Both time and % free resources are displayed in the active window's title bar. - Neither Use this option if you do not want any stats to be shown in the title bar (stats will still be displayed in the icon and the main window's bar graphs). If you select Time, Resources, or Both, then the corresponding statistics will be added to the title bar of each active app. You can restrict which title bars are updated by using the "Exception lists (for title bar additions)" option (below). This option does not affect statistics displayed in WinStats icon or the bar graphs in WinStats main window (in both cases, % free USER heap, GDI heap, and Memory are always displayed). "Clear stats from inactive title bar". When a new window is selected (i.e., made active), resource stats will be displayed in its title bar (unless "Neither" is selected above). This option determines how resource stats will be cleared from the previous window's title bar: - Automatically Causes stats to be automatically cleared from previous window's title bar. - Manually The previous window's title bar will not be cleared. Old stats will remain until cleared manually (see Section 3.2.4 Clear). The "manually" option will rarely be used. It will cause old stats to remain behind in inactive title bars (which can be confusing). However, if you want to see a trace of resource consumption for each app you are running, the "manually" option can be used. In this case, resource stats for each app will remain in its title bar until manually cleared (with Clear option from main window's menu bar). This option does not affect statistics displayed in WinStats icon or the bar graphs in WinStats main window. "Exception lists (for title bar additions)". If you elect to have the active window's title bar updated (by selecting any value other than "Neither" for the "Add stats to title bar" option), you can either update all title bars, or restrict updating to specific title bars (by using an include or exclude list). The include or exclude list contains the names of programs. This list is saved in a file called WINSTATS.CFG in your WinStats program directory. With an include list, ONLY windows owned by programs in the list will have their title bars updated. With an exclude list, those windows owned by programs in the list will NOT have their title bars updated (all other windows will have their title bars updated). If neither list is specified, then program name will NOT be used to restrict which window's title bar will be updated. With this option, you are only specifying what type of list to use (if any). You specify the CONTENTS of the list with the Lists Option in WinStats main menu (see Section 3.2.2 Lists). If you don't know the name of the program associated with a window, the "Pop-up active window's program name" option (below, in this section) can also be used to define the contents of an include or exclude list This option will NOT affect the statistics displayed in WinStats' main window or icon. Note that you cannot specify both types of lists, you must select ONE of the following: - Include Use an Include list to restrict updates. ONLY those Windows associated with programs in the list will have their title bar modified (with resource stats). - Exclude Use an Exclude list to restrict updates. Those windows associated with programs in the list will NOT have their title bar modified (with resource stats). - Neither Regardless of contents of list, ALL title bars will have their title bar modified. "Keep icon always on-top". Set this option to make WinStats' icon float above other windows on your screen. With this option set, you can place WinStats' icon in the corner of your screen and always see the status of Window's Free System Resources. - Yes WinStats icon will float on top. - No WinStats icon will be "normal". "Pop-up active window's program name". This option is used when you want to add the name of the program associated with a window to your include/exclude list, but you don't know the program's name. When this option is set, WinStats will wait for its timer interval (specified by "Monitor Frequency") to expire. Then a dialog box will be displayed with the name of the program that is associated with the currently active window. You will be given the option to add the program name to your existing include/exclude list. In order to use this feature, you will need to insure that the "Monitor Frequency" value is set high enough to give you time to exit the Options window and activate the window you are interested in. Give yourself at least 5 seconds. When you click OK to exit the Options window, you'll get a warning message telling you to quickly activate the window you want to check. After getting the program name(s) you need, don't forget to go back to the Options window and disable this option! - Yes When WinStats' timer expires, it will pop-up with the name of the program associated with the active window (at the moment that the timer expired). - No "Normal" operations. WinStats will display resource stats as defined by the other options set in this window. 3.2.2 Lists ----------- In addition to displaying resource statistics in WinStats icon and main window, you can display these statistics in the title bar of whatever window is active. This gives you a method for always keeping Window's resource data in view. See "Add stats to active title bar" in Section 3.2.1 for details on how to enable/disable title bar updating. If you do not want EVERY title bar updated, WinStats also gives you the ability to restrict updating to specific title bars (by using an include or exclude list). See "Exception lists (for title bar additions)" in Section 3.2.1 for details on how to enable/disable the use of an include or exclude list. If you elect to use an include/exclude list, then the Lists menu on the main window's title bar should be used to define or change the CONTENTS of your list (which is kept in a file called WINSTATS.CFG in your WinStats program directory). Note that either an include or include list can be enabled (but not both). The contents of your include/exclude list are the names of programs that are associated with windows on your screen. If you have specified an include list, then ONLY windows associated with programs in the list will have their title bars updated. If you have specified an exclude list, then windows associated with programs in the list will NOT have their title bars updated (all other windows will have their title bars updated). The Lists menu will open a window that displays the contents of the list and provides two "activities" (add and delete). To add: Enter the program name (i.e., progman.exe for the Program Manager) and click the ADD button. Repeat for all program names you wish to add. To delete: Click mouse on program name you wish to delete, then click the DELETE button. To delete multiple names, hold the CTRL key down while clicking names, then click the DELETE key. When all Additions and deletions are complete, click OK. To cancel the additions/deletions you've made while in this window, click CANCEL (in this case, the include/exclude list's contents will remain as it was prior to opening the Lists window). If you want to add a window to your include/exclude list, but do not know its associated program name, then use the "Pop-up active window's program name" option (see Section 3.2.1). With this option set, WinStats will pop-up a dialog box with the active window's program name and give you the option to add it to your list. 3.2.3 Exit ---------- To exit WinStats, click the Exit menu. 3.2.4 Clear ----------- If you used the "Clear stats from inactive title bar" (see Section 3.2.1) to set the clear option to "manually", then statistics added to each window's title bar will not be cleared when a new window is activated. In this case, use the Clear menu to clear statistics from all windows. The "manually" option will rarely be used. It will cause old stats to remain behind in inactive title bars (which can be confusing). However, if you want to see a trace of resource consumption for each app you are running, the "manually" option can be used. In this case, resource stats for each app will remain in its title bar until manually cleared with Clear menu. 3.2.5 About ----------- Standard About box with information on how to register your copy of WinStats ..... you're gonna register, right??? 4.0 Typical Use of WinStats --------------------------- This section presents typical uses for WinStats and describe the corresponding Options settings. 1) Show Window's Free System Resource statistics in an icon that remains "on top" where it can easily be viewed as you work (statistics will NOT be displayed in title bar of active window). Monitor Frequency any setting Add stats to active title bar Neither Clear stats from inactive title bar any setting Exception lists (for title bar additions) any setting Keep icon always on-top Yes Pop-up active window's program name No To also display statistics in title bar, change the "Add stats to active title bar" to either: Resources, Time, or Both. 2) Show Free System Resources (and current time) in the title bar of active window. Monitor Frequency any setting Add stats to active title bar Resources (or Both) Clear stats from inactive title bar Automatically Exception lists (for title bar additions) Neither Keep icon always on-top No Pop-up active window's program name No 3) Show current time in active title bar of active window and keep icon "on top" with Free System Resources. Monitor Frequency any setting Add stats to active title bar Time Clear stats from inactive title bar Automatically Exception lists (for title bar additions) Neither Keep icon always on-top Yes Pop-up active window's program name No 4) ONLY show Free System Resource statistics in the title bar when the window associated with MYPROG.EXE is active. Monitor Frequency any setting Add stats to active title bar Resources Clear stats from inactive title bar Automatically Exception lists (for title bar additions) Include Keep icon always on-top No Pop-up active window's program name No Define the Include list to contain: myprog.exe 5) Show Free System Resource statistics in the title bar of all active windows EXCEPT when the window associated with MYPROG.EXE is active. Monitor Frequency any setting Add stats to active title bar Resources Clear stats from inactive title bar Automatically Exception lists (for title bar additions) Exclude Keep icon always on-top No Pop-up active window's program name No Define the Include list to contain: myprog.exe 6) You want to exclude Free System Resources from the title bar when a specific window is active, but you don't know that window's program name. Monitor Frequency 5 or more Add stats to active title bar any setting Clear stats from inactive title bar any setting Exception lists (for title bar additions) any setting Keep icon always on-top any setting Pop-up active window's program name Yes A) After clicking OK to exit the Options window, you'll get a warning dialog telling you to quickly activate the appropriate window. Click OK. B) Activate the appropriate window, wait for WinStats timer interval (the value you specified for Monitor Frequency) to expire. At that point, a window will open showing the name of the program associated with the active window. You will be given the option to add this name to your list. Click YES. C) You will then see a dialog box giving you the option of going back to the Options menu. Click YES. D) From the Options menu, set the following (be sure to set the "Pop-up active window's program name" option to No): Monitor Frequency any setting Add stats to active title bar Resources Clear stats from inactive title bar Automatically Exception lists (for title bar additions) Exclude Keep icon always on-top No Pop-up active window's program name No 5.0 Technical Support -------------------- Registered users may send comments, questions, and requests for future enhancements to: Allen Lang 121 Windsor Commons Cranbury, NJ 08512 BE SURE TO INDICATE WHICH VERSION YOU HAVE (click "About" on the menu to see the version number of your copy).